home *** CD-ROM | disk | FTP | other *** search
Wrap
global gWorld, gStates, gObjects, gCurKeyList, void, gCursorlist, gHaveNavs, gTempHotRects, gHotRects, gIndevelopment, sQTCharSprite, gSoundchannels on EnterC01 if getaProp(getaProp(gObjects, #c02worker), #brokenContactLense) = #play then MakeDynamic(#c02worker, #brokenContactLense, #done) playSound("C02wc4.aif", #File, 1) end if end on EnterC03 if getaProp(getaProp(gObjects, #c02worker), #brokenContactLense) = #play then MakeDynamic(#c02worker, #brokenContactLense, #done) playSound("C02wc4.aif", #File, 1) end if end on ExitC01 nothing() end on calcTransToC04 if not (the shiftDown) then set voList to [#c03vowr1.aif, #c03vowr2.aif, #c03vowr3.aif, #C02wc4.aif] repeat with thisSound in voList stopsound(string(thisSound)) end repeat end if return #C04 end on calcTransToC02 if getaProp(getaProp(gStates, #BeenThere), #c02a) > 0 then put #C02c return #C02c else put #c02a return #c02a end if end on GetOutOfC set theWeather to [1: #cloudywarm, 2: #icy, 3: #snowy, 4: #thunder, 5: #rain, 6: #hot, 7: #mild, 8: #cloudycold, 0: 0] set theCurrentWeater to getaProp(getaProp(gStates, #Conditions), #Weather) set currentStateWeatherObj to getOne(theWeather, theCurrentWeater) if voidp(getaProp(getaProp(gStates, #BeenThere), #d01)) and (getaProp(getaProp(gObjects, #weatherObj), #solved) = 1) then setaProp(gStates, #leftC, 1) genexitkf(#d01) else if currentStateWeatherObj = 1 then playSound("c03vowr1.aif", #File, 1) else if (currentStateWeatherObj = 2) and getaProp(getaProp(gStates, #BeenThere), #d01) then playSound("c03vowr3.aif", #File, 1) else if currentStateWeatherObj = 3 then playSound("c03vowr3.aif", #File, 1) else if currentStateWeatherObj = 4 then playSound("c03vowr2.aif", #File, 1) else if currentStateWeatherObj = 5 then playSound("c03vowr2.aif", #File, 1) else if (currentStateWeatherObj = 6) or (currentStateWeatherObj = 7) or (currentStateWeatherObj = 0) then setaProp(gStates, #leftC, 1) if getaProp(getaProp(gObjects, #BBallon), #solved) = #true then genexitkf(#B08B) else genexitkf(#B08A) end if else if currentStateWeatherObj = 8 then playSound("c03vowr1.aif", #File, 1) end if end if end if end if end if end if end if end if end on waitForEndQT OBJref repeat while the movieRate of sprite sQTCharSprite updateStage() end repeat Startthetimer(1, "genExitKF #c03") end on EnterC02 global k set voList to [#c03vowr1.aif, #c03vowr2.aif, #c03vowr3.aif, #C02wc4.aif] repeat with thisSound in voList stopsound(string(thisSound)) end repeat set OBJref to #c02worker set OBj to getaProp(gObjects, OBJref) set the loc of the c02worker of gObjects to the normalLoc of the c02worker of gObjects set the Hotrect of the c02worker of gObjects to the NormalRect of the c02worker of gObjects MakeDynamic(OBJref, #howManyTimes, getaProp(getaProp(gObjects, OBJref), #howManyTimes) + 1) set howManyTimes to getaProp(getaProp(gObjects, OBJref), #howManyTimes) put "howManyTimes =" & howManyTimes set k to 1 if the Weather of the Conditions of gStates = #icy then if (the winC of the weatherObj of gObjects = 1) and voidp(getaProp(getaProp(gStates, #BeenThere), #d01)) then put "condition 8 winC" MakeDynamic(OBJref, #Condition, #end8) MakeDynamic(OBJref, #State, #end8) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else put "condition 8" MakeDynamic(OBJref, #Condition, 8) set alist to [#entry8a, #entry8b, #entry8c, #entry8d] set thisRandomMov to getAt(alist, random(count(alist))) MakeDynamic(OBJref, #State, thisRandomMov) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) end if else if the Weather of the Conditions of gStates = #hot then put "condition 8" MakeDynamic(OBJref, #Condition, 8) set alist to [#entry8a, #entry8b, #entry8c, #entry8d] set thisRandomMov to getAt(alist, random(count(alist))) MakeDynamic(OBJref, #State, thisRandomMov) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = 0 then set the loc of the c02worker of gObjects to the OpenLoc of the c02worker of gObjects set the Hotrect of the c02worker of gObjects to the OpenRect of the c02worker of gObjects MakeDynamic(OBJref, #Condition, 1) MakeDynamic(OBJref, #State, #entry1a) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else if the weatherControl of the Conditions of gStates then put "condition 7" if getaProp(getaProp(gObjects, OBJref), #Condition) < 7 then MakeDynamic(OBJref, #Condition, 7) MakeDynamic(OBJref, #howManyTimes, 1) MakeDynamic(OBJref, #State, 7) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else set alist to [#entry7a, #entry7b, #entry7c] set thisRandomMov to getAt(alist, random(count(alist))) MakeDynamic(OBJref, #State, thisRandomMov) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) end if else if getaProp(getaProp(gObjects, OBJref), #metCondition6) and getaProp(getaProp(gObjects, OBJref), #met2) then put "condition 6" if voidp(getaProp(getaProp(gObjects, OBJref), #met6)) then MakeDynamic(OBJref, #met6, 1) MakeDynamic(OBJref, #Condition, 6) MakeDynamic(OBJref, #howManyTimes, 1) set howManyTimes to getaProp(getaProp(gObjects, OBJref), #howManyTimes) setaProp(getaProp(gObjects, OBJref), #ConCount, 0) end if if howManyTimes > 5 then set thisProp to #entry6f else set thisProp to getaProp([1: #entry6a, 2: #entry6b, 3: #entry6c, 4: #entry6d, 5: #entry6e], howManyTimes) end if MakeDynamic(OBJref, #State, thisProp) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else if getaProp(gStates, #redHerring) and getaProp(getaProp(gObjects, OBJref), #met3) and getaProp(gStates, #leftC) then put "condition 5" MakeDynamic(OBJref, #Condition, 5) MakeDynamic(OBJref, #State, #entry5) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else if voidp(getaProp(gStates, #redHerring)) and getaProp(getaProp(gObjects, OBJref), #met3) and getaProp(gStates, #leftC) then put "condition 4" MakeDynamic(OBJref, #Condition, 4) MakeDynamic(OBJref, #State, #entry4) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else if (the solved of the ThermometerOBJ of gObjects = #false) and (the solved of the windspeedObj of gObjects = #false) and (the solved of the EastWestTempObj of gObjects = #false) and not (getaProp(getaProp(gStates, #BeenThere), #c08) and getaProp(getaProp(gStates, #BeenThere), #c09) and getaProp(getaProp(gStates, #BeenThere), #c10)) and getaProp(getaProp(gObjects, OBJref), #met2) and (howManyTimes > 3) and (getaProp(gStates, #leftC) = 1) then put "condition 3" MakeDynamic(OBJref, #Condition, 3) MakeDynamic(OBJref, #met3, 1) MakeDynamic(OBJref, #State, #entry3) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) else put "condition 2" MakeDynamic(OBJref, #Condition, 2) MakeDynamic(OBJref, #met2, 1) setaProp(getaProp(gObjects, OBJref), #ConCount, 0) if howManyTimes = 1 then set the loc of the c02worker of gObjects to the OpenLoc of the c02worker of gObjects set the Hotrect of the c02worker of gObjects to the OpenRect of the c02worker of gObjects set thisProp to #entry1a else if howManyTimes = 2 then set thisProp to #entry2b MakeDynamic(#c02worker, #brokenContactLense, #play) else if howManyTimes = 3 then set thisProp to #entry2c else if howManyTimes > 3 then set thisProp to #entry2D end if end if end if end if MakeDynamic(OBJref, #State, thisProp) MakeDynamic(OBJref, #DisplayState, getaProp(OBj, #State)) end if end if end if end if end if end if end if end if end on doC02workerVid set OBJref to #c02worker set myObj to getaProp(gObjects, OBJref) set howManyTimes to getaProp(getaProp(gObjects, OBJref), #howManyTimes) set the loc of the c02worker of gObjects to the normalLoc of the c02worker of gObjects set the Hotrect of the c02worker of gObjects to the NormalRect of the c02worker of gObjects if getaProp(getaProp(gObjects, OBJref), #Condition) = 1 then set the loc of the c02worker of gObjects to the OpenLoc of the c02worker of gObjects set the Hotrect of the c02worker of gObjects to the OpenRect of the c02worker of gObjects MakeDynamic(OBJref, #State, 1) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = 2 then if the howManyTimes of myObj = 2 then put "howManytimes=" && howManyTimes MakeDynamic(OBJref, #State, 2) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if the howManyTimes of myObj > 2 then MakeDynamic(OBJref, #State, #b2) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) end if end if else if getaProp(getaProp(gObjects, OBJref), #Condition) = 3 then MakeDynamic(OBJref, #State, 3) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = 4 then MakeDynamic(OBJref, #State, 4) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = 5 then MakeDynamic(OBJref, #State, 5) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = 6 then if the howManyTimes of myObj = 1 then MakeDynamic(OBJref, #State, 6) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if the howManyTimes of myObj = 2 then MakeDynamic(OBJref, #State, #a6) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if the howManyTimes of myObj = 3 then MakeDynamic(OBJref, #State, #b6) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if the howManyTimes of myObj = 4 then MakeDynamic(OBJref, #State, #c6) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if the howManyTimes of myObj = 5 then MakeDynamic(OBJref, #State, #d6) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if the howManyTimes of myObj = 6 then MakeDynamic(OBJref, #State, #e6) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) end if end if end if end if end if end if else if getaProp(getaProp(gObjects, OBJref), #Condition) = 7 then if the howManyTimes of myObj = 1 then set thisRandomMov to 7 else set alist to [#entry7a, #entry7b, #entry7c] set thisRandomMov to getAt(alist, random(count(alist))) end if MakeDynamic(OBJref, #State, thisRandomMov) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = 8 then set alist to [#entry7a, #entry7c] set thisRandomMov to getAt(alist, random(count(alist))) MakeDynamic(OBJref, #State, thisRandomMov) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) else if getaProp(getaProp(gObjects, OBJref), #Condition) = #end8 then MakeDynamic(OBJref, #State, #end8) MakeDynamic(OBJref, #DisplayState, getaProp(myObj, #State)) end if end if end if end if end if end if end if end if end if DoCharacterMovie(OBJref) end on EnterC08 if getaProp(getaProp(gStates, #BeenThere), #c08) = 0 then Startthetimer(30, "playSound " & QUOTE & "C08vowrk.aif" & QUOTE & ",#file, 1", #ThermometerOBJ) end if if getaProp(getaProp(gObjects, #BRocket), #solved) = #true then MakeDynamic(#ThermometerOBJ, #State, #on) else MakeDynamic(#ThermometerOBJ, #State, #off) end if turnOnObj(#ThermometerOBJ) if getaProp(getaProp(gStates, #BeenThere), #c10) > 0 then if (the State of the ThermometerOBJ of gObjects = #off) and (the State of the EastWestTempObj of gObjects = #off) then PDARelease("J04m03p.mov") end if end if end on EnterC09 if getaProp(getaProp(gStates, #BeenThere), #c09) = 0 then Startthetimer(30, "playSound " & QUOTE & "C09vowrk.aif" & QUOTE & ", #file, 1", #windspeedObj) end if MakeDynamic(#windspeedObj, #State, #on) turnOnObj(#windspeedObj) end on ExitC09 DelObjects([getaProp(getaProp(gObjects, #windSpeedgraph), #State)]) end